<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core">

<ui:composition template="/administracao.xhtml">
	<ui:define name="content">
		<div class="grid_10">
			<div class="box round first">
				<h2>Cadastrar Clientes</h2>
				<div class="block">
					<h:form>
						<h:panelGrid columns="2" class="form">
							<h:column class="col1" >
								<h:outputLabel value="Nome" />
							</h:column>
							<h:column class="col2">
								<h:inputText value="#{clienteBean.nome}" id="nome" required="true" requiredMessage="O campo Nome não pode ficar em branco" class="mini" />
								<span class="error"><h:message for="nome" /></span>
							</h:column>
							<h:column>
								<h:outputLabel value="CPF" />
							</h:column>
							<h:column>
								<h:inputText value="" id="cpf" required="true" requiredMessage="O campo CPF não pode ficar em branco" />
								<span class="error"><h:message for="cpf" /></span>
							</h:column>
							<h:column>
								<h:outputLabel value="Endereço" />
							</h:column>
							<h:column>
								<h:inputText value="" id="endereco" required="true" requiredMessage="O campo Endereço não pode ficar em branco"  class="mini"/>
								<span class="error"><h:message for="endereco" /></span>
							</h:column>
							
							<h:column>
								<h:outputLabel value="Número" />
							</h:column>
							<h:column>
								<h:inputText value="" id="numero" required="true" requiredMessage="O campo Número não pode ficar em branco" />
								<span class="error"><h:message for="numero" /></span>
							</h:column>
							
							<h:column>
								<h:outputLabel value="Bairro" />
							</h:column>
							<h:column>
								<h:inputText value="" id="bairro" required="true" requiredMessage="O campo Bairro não pode ficar em branco" />
								<span class="error"><h:message for="bairro" /></span>
							</h:column>
							
							<h:column>
								<h:outputLabel value="Complemento" />
							</h:column>
							<h:column>
								<h:inputText value="" id="complemento" required="false" class="mini" />
							</h:column>
							
							<h:column>
								<h:outputLabel value="Estado" />
							</h:column>
							<h:column>
								<h:selectOneListbox required="true" id="estado" requiredMessage="Selecione o Estado">
									<f:selectItem itemValue="SP" />
								</h:selectOneListbox>
								<span class="error"><h:message for="estado" /></span>
							</h:column>
							<h:column>
								<h:commandLink action="#{clienteBean.salvar}" class="btn-icon btn-grey btn-plus" ><span></span>Cadastrar</h:commandLink>
							</h:column>
						</h:panelGrid>
					</h:form>
				</div>
			</div>
		</div>
		<div class="clear"></div>
	</ui:define>
</ui:composition>
</html>